<template>
  <div>
    <el-table
      :data="tableData"
      style="width: 100%">
      <el-table-column
        prop="NOTICE"
        label="消息内容">
      </el-table-column>
      <el-table-column
        prop="CREATETIME"
        label="通知时间">
      </el-table-column>
    </el-table>
  </div>
</template>

<script>
import { getNewsList } from '@/api/api'

export default {
  name: 'news',
  data() {
    return {
      tableData: []
    }
  },
  created() {
    this.getNewsList()
  },
  methods: {
    /* 获取通知消息列表 */
    getNewsList() {
      getNewsList().then(res => {
        console.log(res)
        if (res.code == 200) {
          this.tableData = res.data.DATA.list
        }
      })
    }
  }
}
</script>

<style scoped>

</style>
